<?xml version="1.0" encoding="iso-8859-1"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  <html xmlns="http://www.w3.org/1999/xhtml">
		<head>
			<!-- template designed by Marco Von Ballmoos -->
			<title>Docs For Class uhu_collection_basic</title>
			<link rel="stylesheet" href="../../media/stylesheet.css" />
			<meta http-equiv='Content-Type' content='text/html; charset=iso-8859-1'/>
		</head>
		<body>
			<div class="page-body">			
<h2 class="class-name">Class uhu_collection_basic</h2>

<a name="sec-description"></a>
<div class="info-box">
	<div class="info-box-title">Description</div>
	<div class="nav-bar">
					<span class="disabled">Description</span> |
							<a href="#sec-descendents">Descendents</a>
			|											<a href="#sec-var-summary">Vars</a> (<a href="#sec-vars">details</a>)
						|											<a href="#sec-method-summary">Methods</a> (<a href="#sec-methods">details</a>)
						
					</div>
	<div class="info-box-body">
                <p class="implements">
            Implements interfaces:
            <ul>
                <li><a href="../../UHU_Components/Collections/uhu_collection.html">uhu_collection</a></li>            </ul>
        </p>
        		<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Defines a basic general-purpose collection object</p>
	<ul class="tags">
				<li><span class="field">abstract:</span> </li>
				<li><span class="field">usedby:</span> <a href="../../UHU_Components/Collections/uhu_collection_class.html">uhu_collection_class</a></li>
				<li><span class="field">uses:</span> <a href="../../UHU_Components/Collections/uhu_collection.html">uhu_collection</a></li>
			</ul>
		<p class="notes">
			Located in <a class="field" href="_uhu---collection.php.html">/uhu/collection.php</a> (line <span class="field">35</span>)
		</p>
		
				
		<pre></pre>
	
			</div>
</div>

	<a name="sec-descendents"></a>
	<div class="info-box">
		<div class="info-box-title">Direct descendents</div>
		<div class="nav-bar">
			<a href="#sec-description">Description</a> |
			<span class="disabled">Descendents</span>
			|												<a href="#sec-var-summary">Vars</a> (<a href="#sec-vars">details</a>)
								|															<a href="#sec-method-summary">Methods</a> (<a href="#sec-methods">details</a>)
							
								</div>
		<div class="info-box-body">
			<table cellpadding="2" cellspacing="0" class="class-table">
				<tr>
					<th class="class-table-header">Class</th>
					<th class="class-table-header">Description</th>
				</tr>
								<tr>
					<td style="padding-right: 2em"><a href="../../UHU_Components/Collections/uhu_collection_class.html">uhu_collection_class</a></td>
					<td>
											Provides automated validation of collection values that are intended to be an instance of a pre-determined class
										</td>
				</tr>
							</table>
		</div>
	</div>


	<a name="sec-var-summary"></a>
	<div class="info-box">
		<div class="info-box-title">Variable Summary</span></div>
		<div class="nav-bar">
			<a href="#sec-description">Description</a> |
							<a href="#sec-descendents">Descendents</a> |
						<span class="disabled">Vars</span> (<a href="#sec-vars">details</a>)
							| 
									<a href="#sec-method-summary">Methods</a> (<a href="#sec-methods">details</a>)
							
								</div>
		<div class="info-box-body">
			<div class="var-summary">
																								<div class="var-title">
					<span class="var-type">array</span>
					<a href="#$collection" title="details" class="var-name">$collection</a>
				</div>
											</div>
		</div>
	</div>

	<a name="sec-method-summary"></a>
	<div class="info-box">
		<div class="info-box-title">Method Summary</span></div>
		<div class="nav-bar">
			<a href="#sec-description">Description</a> |
							<a href="#sec-descendents">Descendents</a> |
																		<a href="#sec-var-summary">Vars</a> (<a href="#sec-vars">details</a>)
				 
				|
						<span class="disabled">Methods</span> (<a href="#sec-methods">details</a>)
		</div>
		<div class="info-box-body">			
			<div class="method-summary">
																																																																																																				
												<div class="method-definition">
											<span class="method-result">uhu_collection_basic</span>
										<a href="#__construct" title="details" class="method-name">__construct</a>
											([<span class="var-type"></span>&nbsp;<span class="var-name">$items</span> = <span class="var-default">null</span>])
									</div>
																<div class="method-definition">
											<span class="method-result">integer</span>
										<a href="#count" title="details" class="method-name">count</a>
										()
									</div>
																<div class="method-definition">
											<span class="method-result">mixed</span>
										<a href="#current" title="details" class="method-name">current</a>
										()
									</div>
																<div class="method-definition">
											<span class="method-result">mixed</span>
										<a href="#key" title="details" class="method-name">key</a>
										()
									</div>
																<div class="method-definition">
											<span class="method-result">mixed</span>
										<a href="#next" title="details" class="method-name">next</a>
										()
									</div>
																<div class="method-definition">
											<span class="method-result">bool</span>
										<a href="#offsetExists" title="details" class="method-name">offsetExists</a>
											(<span class="var-type"></span>&nbsp;<span class="var-name">$offset</span>)
									</div>
																<div class="method-definition">
											<span class="method-result">mixed</span>
										<a href="#offsetGet" title="details" class="method-name">offsetGet</a>
											(<span class="var-type"></span>&nbsp;<span class="var-name">$offset</span>)
									</div>
																<div class="method-definition">
											<span class="method-result">void</span>
										<a href="#offsetSet" title="details" class="method-name">offsetSet</a>
											(<span class="var-type"></span>&nbsp;<span class="var-name">$offset</span>, <span class="var-type"></span>&nbsp;<span class="var-name">$value</span>)
									</div>
																<div class="method-definition">
											<span class="method-result">void</span>
										<a href="#offsetUnset" title="details" class="method-name">offsetUnset</a>
											(<span class="var-type"></span>&nbsp;<span class="var-name">$offset</span>)
									</div>
																<div class="method-definition">
											<span class="method-result">mixed</span>
										<a href="#rewind" title="details" class="method-name">rewind</a>
										()
									</div>
																<div class="method-definition">
											<span class="method-result">bool</span>
										<a href="#valid" title="details" class="method-name">valid</a>
										()
									</div>
																<div class="method-definition">
											<span class="method-result">void</span>
										<a href="#validate_offset" title="details" class="method-name">validate_offset</a>
											(<span class="var-type"></span>&nbsp;<span class="var-name">$offset</span>)
									</div>
								</div>
		</div>
	</div>		

	<a name="sec-vars"></a>
	<div class="info-box">
		<div class="info-box-title">Variables</div>
		<div class="nav-bar">
			<a href="#sec-description">Description</a> |
							<a href="#sec-descendents">Descendents</a> |
										<a href="#sec-var-summary">Vars</a> (<span class="disabled">details</span>)
						
			
										| 
									<a href="#sec-method-summary">Methods</a> (<a href="#sec-methods">details</a>)
							
					</div>
		<div class="info-box-body">
			<a name="var$collection" id="$collection"><!-- --></A>
<div class="oddrow">

	<div class="var-header">
		<span class="var-title">
			<span class="var-type">array</span>
			<span class="var-name">$collection</span>
			 = <span class="var-default">array()</span>			(line <span class="line-number">40</span>)
		</span>
	</div>

	<!-- ========== Info from phpDoc block ========= -->
	<ul class="tags">
				<li><span class="field">var:</span> An array to hold the collection items</li>
				<li><span class="field">access:</span> protected</li>
				<li><span class="field">usedby:</span> <a href="../../UHU_Components/Collections/uhu_collection_basic.html#methodoffsetExists">uhu_collection_basic::offsetExists()</a></li>
				<li><span class="field">usedby:</span> <a href="../../UHU_Components/Collections/uhu_collection_basic.html#methodoffsetUnset">uhu_collection_basic::offsetUnset()</a></li>
				<li><span class="field">usedby:</span> <a href="../../UHU_Components/Collections/uhu_collection_basic.html#methodoffsetGet">uhu_collection_basic::offsetGet()</a></li>
				<li><span class="field">usedby:</span> <a href="../../UHU_Components/Collections/uhu_collection_basic.html#methodoffsetSet">uhu_collection_basic::offsetSet()</a></li>
				<li><span class="field">usedby:</span> <a href="../../UHU_Components/Collections/uhu_collection_basic.html#methodvalid">uhu_collection_basic::valid()</a></li>
				<li><span class="field">usedby:</span> <a href="../../UHU_Components/Collections/uhu_collection_basic.html#methodrewind">uhu_collection_basic::rewind()</a></li>
				<li><span class="field">usedby:</span> <a href="../../UHU_Components/Collections/uhu_collection_basic.html#methodcount">uhu_collection_basic::count()</a></li>
				<li><span class="field">usedby:</span> <a href="../../UHU_Components/Collections/uhu_collection_basic.html#methodcurrent">uhu_collection_basic::current()</a></li>
				<li><span class="field">usedby:</span> <a href="../../UHU_Components/Collections/uhu_collection_basic.html#methodkey">uhu_collection_basic::key()</a></li>
				<li><span class="field">usedby:</span> <a href="../../UHU_Components/Collections/uhu_collection_basic.html#methodnext">uhu_collection_basic::next()</a></li>
			</ul>
	
	
		
		

</div>
						
		</div>
	</div>
	
	<a name="sec-methods"></a>
	<div class="info-box">
		<div class="info-box-title">Methods</div>
		<div class="nav-bar">
			<a href="#sec-description">Description</a> |
							<a href="#sec-descendents">Descendents</a> |
															<a href="#sec-var-summary">Vars</a> (<a href="#sec-vars">details</a>)
																	<a href="#sec-method-summary">Methods</a> (<span class="disabled">details</span>)
						
		</div>
		<div class="info-box-body">
			<A NAME='method_detail'></A>

<a name="method__construct" id="__construct"><!-- --></a>
<div class="evenrow">
	
	<div class="method-header">
		<span class="method-title">Constructor __construct</span> (line <span class="line-number">53</span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Creates the collection object, optionally adding items on instantiation</p>
	<ul class="tags">
				<li><span class="field">access:</span> public</li>
				<li><span class="field">uses:</span> <a href="../../UHU_Components/Collections/uhu_collection_basic.html#methodoffsetSet">uhu_collection_basic::offsetSet()</a></li>
			</ul>
	
	<div class="method-signature">
		<span class="method-result">uhu_collection_basic</span>
		<span class="method-name">
			__construct
		</span>
					([<span class="var-type"></span>&nbsp;<span class="var-name">$items</span> = <span class="var-default">null</span>])
			</div>
	
			<ul class="parameters">
					<li>
				<span class="var-type">array|null</span>
				<span class="var-name">$items</span><span class="var-description">: Optional array of items to add when instantiating the collection</span>			</li>
				</ul>
		
			
	</div>
<a name="methodcount" id="count"><!-- --></a>
<div class="oddrow">
	
	<div class="method-header">
		<span class="method-title">count</span> (line <span class="line-number">67</span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
	<ul class="tags">
				<li><span class="field">return:</span> The number of items in the collection</li>
				<li><span class="field">access:</span> public</li>
				<li><span class="field">uses:</span> <a href="../../UHU_Components/Collections/uhu_collection_basic.html#var$collection">uhu_collection_basic::$collection</a></li>
			</ul>
	
	<div class="method-signature">
		<span class="method-result">integer</span>
		<span class="method-name">
			count
		</span>
				()
			</div>
	
		
			
	</div>
<a name="methodcurrent" id="current"><!-- --></a>
<div class="evenrow">
	
	<div class="method-header">
		<span class="method-title">current</span> (line <span class="line-number">75</span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
	<ul class="tags">
				<li><span class="field">return:</span> The curren item in the collection</li>
				<li><span class="field">access:</span> public</li>
				<li><span class="field">uses:</span> <a href="../../UHU_Components/Collections/uhu_collection_basic.html#var$collection">uhu_collection_basic::$collection</a></li>
			</ul>
	
	<div class="method-signature">
		<span class="method-result">mixed</span>
		<span class="method-name">
			current
		</span>
				()
			</div>
	
		
			
	</div>
<a name="methodkey" id="key"><!-- --></a>
<div class="oddrow">
	
	<div class="method-header">
		<span class="method-title">key</span> (line <span class="line-number">83</span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
	<ul class="tags">
				<li><span class="field">return:</span> The key for the curren item in the collection</li>
				<li><span class="field">access:</span> public</li>
				<li><span class="field">uses:</span> <a href="../../UHU_Components/Collections/uhu_collection_basic.html#var$collection">uhu_collection_basic::$collection</a></li>
			</ul>
	
	<div class="method-signature">
		<span class="method-result">mixed</span>
		<span class="method-name">
			key
		</span>
				()
			</div>
	
		
			
	</div>
<a name="methodnext" id="next"><!-- --></a>
<div class="evenrow">
	
	<div class="method-header">
		<span class="method-title">next</span> (line <span class="line-number">91</span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
	<ul class="tags">
				<li><span class="field">return:</span> Advances the array pointer for the collection</li>
				<li><span class="field">access:</span> public</li>
				<li><span class="field">uses:</span> <a href="../../UHU_Components/Collections/uhu_collection_basic.html#var$collection">uhu_collection_basic::$collection</a></li>
			</ul>
	
	<div class="method-signature">
		<span class="method-result">mixed</span>
		<span class="method-name">
			next
		</span>
				()
			</div>
	
		
			
	</div>
<a name="methodoffsetExists" id="offsetExists"><!-- --></a>
<div class="oddrow">
	
	<div class="method-header">
		<span class="method-title">offsetExists</span> (line <span class="line-number">115</span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
	<ul class="tags">
				<li><span class="field">return:</span> Returns TRUE if an item exists at the specified offset exists in the collection</li>
				<li><span class="field">access:</span> public</li>
				<li><span class="field">uses:</span> <a href="../../UHU_Components/Collections/uhu_collection_basic.html#var$collection">uhu_collection_basic::$collection</a></li>
			</ul>
	
	<div class="method-signature">
		<span class="method-result">bool</span>
		<span class="method-name">
			offsetExists
		</span>
					(<span class="var-type"></span>&nbsp;<span class="var-name">$offset</span>)
			</div>
	
			<ul class="parameters">
					<li>
				<span class="var-type"></span>
				<span class="var-name">$offset</span>			</li>
				</ul>
		
			
	</div>
<a name="methodoffsetGet" id="offsetGet"><!-- --></a>
<div class="evenrow">
	
	<div class="method-header">
		<span class="method-title">offsetGet</span> (line <span class="line-number">131</span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
	<ul class="tags">
				<li><span class="field">return:</span> Returns the item at the specified offset in the collection, or NULL if no such item exists</li>
				<li><span class="field">access:</span> public</li>
				<li><span class="field">uses:</span> <a href="../../UHU_Components/Collections/uhu_collection_basic.html#var$collection">uhu_collection_basic::$collection</a></li>
			</ul>
	
	<div class="method-signature">
		<span class="method-result">mixed</span>
		<span class="method-name">
			offsetGet
		</span>
					(<span class="var-type"></span>&nbsp;<span class="var-name">$offset</span>)
			</div>
	
			<ul class="parameters">
					<li>
				<span class="var-type"></span>
				<span class="var-name">$offset</span>			</li>
				</ul>
		
			
	</div>
<a name="methodoffsetSet" id="offsetSet"><!-- --></a>
<div class="oddrow">
	
	<div class="method-header">
		<span class="method-title">offsetSet</span> (line <span class="line-number">141</span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
	<ul class="tags">
				<li><span class="field">return:</span> Adds the item provided to the collection at the specified offset. If the offset is null (via $foo[] = 'bar'; ), then the offset is set to the number of entries in the collection</li>
				<li><span class="field">access:</span> public</li>
				<li><span class="field">usedby:</span> <a href="../../UHU_Components/Collections/uhu_collection_basic.html#method__construct">uhu_collection_basic::__construct()</a></li>
				<li><span class="field">uses:</span> <a href="../../UHU_Components/Collections/uhu_collection_basic.html#methodvalidate_offset">uhu_collection_basic::validate_offset()</a></li>
				<li><span class="field">uses:</span> <a href="../../UHU_Components/Collections/uhu_collection_basic.html#var$collection">uhu_collection_basic::$collection</a></li>
				<li><span class="field">uses:</span> <a href="../../UHU_Components/Collections/uhu_collection.html#methodvalidate_value">uhu_collection::validate_value()</a></li>
			</ul>
	
	<div class="method-signature">
		<span class="method-result">void</span>
		<span class="method-name">
			offsetSet
		</span>
					(<span class="var-type"></span>&nbsp;<span class="var-name">$offset</span>, <span class="var-type"></span>&nbsp;<span class="var-name">$value</span>)
			</div>
	
			<ul class="parameters">
					<li>
				<span class="var-type"></span>
				<span class="var-name">$offset</span>			</li>
					<li>
				<span class="var-type"></span>
				<span class="var-name">$value</span>			</li>
				</ul>
		
			
	</div>
<a name="methodoffsetUnset" id="offsetUnset"><!-- --></a>
<div class="evenrow">
	
	<div class="method-header">
		<span class="method-title">offsetUnset</span> (line <span class="line-number">123</span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
	<ul class="tags">
				<li><span class="field">return:</span> Removes the item at the specified offset in the collection</li>
				<li><span class="field">access:</span> public</li>
				<li><span class="field">uses:</span> <a href="../../UHU_Components/Collections/uhu_collection_basic.html#var$collection">uhu_collection_basic::$collection</a></li>
			</ul>
	
	<div class="method-signature">
		<span class="method-result">void</span>
		<span class="method-name">
			offsetUnset
		</span>
					(<span class="var-type"></span>&nbsp;<span class="var-name">$offset</span>)
			</div>
	
			<ul class="parameters">
					<li>
				<span class="var-type"></span>
				<span class="var-name">$offset</span>			</li>
				</ul>
		
			
	</div>
<a name="methodrewind" id="rewind"><!-- --></a>
<div class="oddrow">
	
	<div class="method-header">
		<span class="method-title">rewind</span> (line <span class="line-number">99</span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
	<ul class="tags">
				<li><span class="field">return:</span> resets the array pointer for the collection</li>
				<li><span class="field">access:</span> public</li>
				<li><span class="field">uses:</span> <a href="../../UHU_Components/Collections/uhu_collection_basic.html#var$collection">uhu_collection_basic::$collection</a></li>
			</ul>
	
	<div class="method-signature">
		<span class="method-result">mixed</span>
		<span class="method-name">
			rewind
		</span>
				()
			</div>
	
		
			
	</div>
<a name="methodvalid" id="valid"><!-- --></a>
<div class="evenrow">
	
	<div class="method-header">
		<span class="method-title">valid</span> (line <span class="line-number">107</span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
	<ul class="tags">
				<li><span class="field">return:</span> Returns TRUE if there is an item on the current array pointer</li>
				<li><span class="field">access:</span> public</li>
				<li><span class="field">uses:</span> <a href="../../UHU_Components/Collections/uhu_collection_basic.html#var$collection">uhu_collection_basic::$collection</a></li>
			</ul>
	
	<div class="method-signature">
		<span class="method-result">bool</span>
		<span class="method-name">
			valid
		</span>
				()
			</div>
	
		
			
	</div>
<a name="methodvalidate_offset" id="validate_offset"><!-- --></a>
<div class="oddrow">
	
	<div class="method-header">
		<span class="method-title">validate_offset</span> (line <span class="line-number">45</span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">An empty offset validator, leaves offset errors up to the PHP core</p>
	<ul class="tags">
				<li><span class="field">access:</span> public</li>
				<li><span class="field">usedby:</span> <a href="../../UHU_Components/Collections/uhu_collection_basic.html#methodoffsetSet">uhu_collection_basic::offsetSet()</a></li>
				<li><span class="field">uses:</span> <a href="../../UHU_Components/Collections/uhu_collection.html#methodvalidate_offset">uhu_collection::validate_offset()</a></li>
			</ul>
	
	<div class="method-signature">
		<span class="method-result">void</span>
		<span class="method-name">
			validate_offset
		</span>
					(<span class="var-type"></span>&nbsp;<span class="var-name">$offset</span>)
			</div>
	
			<ul class="parameters">
					<li>
				<span class="var-type"></span>
				<span class="var-name">$offset</span>			</li>
				</ul>
		
				<hr class="separator" />
		<div class="notes">Implementation of:</div>
			<dl>
			<dt><a href="../../UHU_Components/Collections/uhu_collection.html#methodvalidate_offset">uhu_collection::validate_offset()</a></dt>
						<dd>Intended to throw an InvalidArgumentException object if the offset is not to be accepted for the instantiated collection.</dd>
					</dl>
			
	</div>
						
		</div>
	</div>


	<p class="notes" id="credit">
		Documentation generated on Tue, 13 Jan 2009 23:21:44 +0000 by <a href="http://www.phpdoc.org" target="_blank">phpDocumentor 1.4.1</a>
	</p>
	</div></body>
</html>